package com.mall.admin;

import lombok.extern.slf4j.Slf4j;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.ComponentScan;
import springfox.documentation.swagger2.annotations.EnableSwagger2WebMvc;


@SpringBootApplication
@Slf4j
@EnableSwagger2WebMvc
//扫描所有模块
@ComponentScan(basePackages = {
    "com.mall.admin",
    "com.mall.framework",
    "com.mall.module.system",
    "com.mall.module.product"
})
@MapperScan("com.mall.**.mapper")
public class MallApplication {
    public static void main(String[] args) {
        SpringApplication.run(MallApplication.class, args);
        log.info("MallApplication is starting...");
        log.info("http://localhost:8080/doc.html");
    }
}
